//
//  CSMACANoVCSListener.hpp
//  WiFiMACSim
//
//  Created by Christopher Kemsley on 4/1/12.
//  Copyright (c) 2012 iAppolopolis. All rights reserved.
//

#ifndef WiFiMACSim_CSMACANoVCSListener_hpp
#define WiFiMACSim_CSMACANoVCSListener_hpp

#include "Node.hpp"
#include "Message.hpp"
#include "Medium.hpp"
#include "Message.hpp"

SimNamespaceBegin





class	CSMACANoVCSListener : public TransitionalStateMachineNode<CSMACANoVCSListener>
{
public:
	
	enum {
		kStateIdle				=	0 ,
		kStateSendingAck		=	105 ,
	} ;
	
	
	SlotTimer	timer ;
	
	static const UInteger	Infinity	=	((UInteger)(-1)) ;
	
	ID			sender ;
	Message*	message ;
	
	
	
	
	CSMACANoVCSListener ( ID const & name ) ;
	
	
	
	
	
	
	void	update_idle		( Message * incoming , bool completed , bool isBusy ) ;
	
	void	update_xmitAck	( Message * incoming , bool completed , bool isBusy ) ;
} ;



SimNamespaceEnd
#endif
